<template>
  <div class="Deviceabnormal">
    <section class="toolTop">
      <el-form :inline="true" class="demo-form-inline">
        <el-row :gutter="24">
          <el-col :span="24">
            <el-form-item>
              <el-button>批量删除</el-button>
              <el-button>异常报告</el-button>
              <el-button>问题分配</el-button>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
    </section>
    <section class="main_table">
      <el-table
        ref="multipleTable"
        v-bind:data="deviceabnormalData"
        style="width: 100%"
        v-bind:max-height="height"
        v-bind:header-cell-style="{background: '#1f2548',color:'#ffffff'}"
        v-bind:cell-style="{padding:'10px'}"
        @selection-change="handleSelectionChange"
        fit
      >
        <el-table-column align="center" type="selection" width="55px"></el-table-column>
        <el-table-column align="center" sortable prop="deviceId" label="设备编号" max-width="120"></el-table-column>
        <el-table-column align="center" sortable prop="exceptionType" label="异常类别" max-width="120"></el-table-column>
        <el-table-column align="center" sortable prop="description" label="异常描述" max-width="120"></el-table-column>
        <el-table-column align="center" prop="remarks" label="备注" max-width="120"></el-table-column>
      </el-table>
      <section class="toolFoot">
        <el-row :gutter="25">
          <el-col :span="24" class="rightCol">
            <el-pagination
              small
              @size-change="handleSizeChange"
              @current-change="handleCurrentChange"
              :current-page="currentPage"
              :page-sizes="[5, 10, 15, 20]"
              :page-size="pagesize"
              layout="total, sizes, prev, pager, next ,jumper"
              :total="total"
              :pager-count="5"
            ></el-pagination>
          </el-col>
        </el-row>
      </section>
    </section>
  </div>
</template>

<script type="text/javascript" src="../../api/devicemg/deviceabnormal.js">
</script>

<style lang="scss">
.Deviceabnormal {
  flex: 1;
  > section {
    &.toolTop {
      height: auto !important;
      padding-bottom: 5px;
      > .el-form {
        border-radius: 5px;
        padding: 8px 16px;
        .el-form-item {
          margin-bottom: 0px;
          .el-button {
            background-color: #161836;
            font-size: 14px;
            padding: 8px 16px;
            color: #85899C;
            border:1px solid #85899C
          }
          .el-button:hover,.el-button:focus{
            background-color: #161836;
            font-size: 14px;
            padding: 8px 16px;
            color: #fff;
            border:1px solid #fff
          }
        }
      }
    }

    &.main_table {
      padding: 14px;
      margin-bottom: 16px;
      border-radius: 5px;
      > .toolFoot {
        margin-top: 16px;
        .rightCol {
          text-align: right;
          .el-pagination--small {
            white-space: nowrap;
            padding: 2px 5px;
            color: #303133;
            font-weight: 700;
            height: 50px;
            span {
              color: #fff;
              line-height: 30px;
              .el-input {
                .el-input__inner {
                  height: 30px;
                  line-height: 30px;
                }
              }
            }
          }
        }
      }
    }
  }
}
</style>
